1. Field of the Invention
The present invention relates to a magnetic recording/reproducing apparatus, such as a hard disk drive (HDD), and a data output method thereof.
More particularly, the present invention relates to a magnetic recording/reproducing apparatus and a data output method thereof suitable for executing data reproduction having sufficient continuity for a viewer (also referred to as a xe2x80x98userxe2x80x99) even if an error occurs while the apparatus is reading data from a recording medium.
2. Description of the Prior Art
In an information processing system, such as a personal computer, an HDD may be used as an auxiliary storage unit.
In the HDD, during a data recording process, data such as image data and audio data are respectively divided, compressed by coding, and sequentially written into a plurality of different sectors on a magnetic disk unit. On the other hand, during a data reproducing process, the recorded data is sequentially read using ID information (also referred to as xe2x80x98address informationxe2x80x99), which is allocated to each sector on the magnetic disk unit, at the request of the information processing system.
An error may happen to the magnetic disk unit or to the operation environment during the data reproducing process, in which case the HDD cannot recognize the ID information on one sector at least. If the case occurs, the HDD re-executes (hereinafter referred to as xe2x80x98retriesxe2x80x99) the data reading from the sectors.
Data recorded on a magnetic disk unit includes both data to be processed by electronic equipment such as a computer, and data to be output to a human, such as audio-visual (AV) data. Certain repeatability is required to the former, while reproduction having sufficient continuity for a viewer is required to the latter.
To the latter, the repeatability on the same level as that required to the former is not always required because of the low analytical capacity of a human, while a delay in data reproduction must be avoided even if part of the data cannot be read normally.
That is, in a case where a host system requests the HDD to read data designated by a user, the HDD must read the data from the magnetic disk unit and transfer it to the host system (hereinafter, referred to as xe2x80x98host transferxe2x80x99) within a predetermined time. Guaranteeing the rate of host transfer has first priority. Therefore, a limit is placed on a retry count in the reading process.
A command set which specifies the procedure for transferring AV data between the HDD and the host system, such as AV-HDD, is proposed. According to the AV-HDD, the HDD executes the retry in the following cases: (1) where a reading error is detected by the HDD after the end of a reading process or (2) where an error is detected before the start of a reading process owing to miswriting or positioning difficulty owing to head shaking caused by heat or vibration. And even while executing the retry, the HDD stops the retry at the point of time when a processing time designated by the host system elapses.
In order to avoid suspending the operation of the host system, the HDD must transfer any data to the host system even in the case where the retry is stopped as described above. Therefore, the HDD transfers a normal end status (also referred to as a xe2x80x98no-error statusxe2x80x99) and dummy data to the host system. That is, the HDD does not inform the host system of the error.
The HDD adopts optionally selected data or predetermined data (hereinafter collectively referred to as xe2x80x98optional dataxe2x80x99), such as xe2x80x9800xe2x80x99, as dummy data.
Consequently, the host system can receive some data from the HDD within the designated processing time and execute the data reproduction having sufficient continuity for a viewer.
However, the aforementioned optional data is independent of or remotely related to the data that is to be read originally. As a result, a piece of image data in correspondence to one sector on the magnetic disk unit may be skipped on a display screen owing to a piece of optional data (hereinafter referred to as xe2x80x98frame skippingxe2x80x99) for example.
In the meantime, an error correction code (ECC) error, which is one of the reading errors caused by the HDD, may occur. In this case, data is read from the magnetic disk unit, accompanied by an error or missing portion. And the read data (hereinafter referred to as xe2x80x98partially-missed dataxe2x80x99), which is more useful than optional data as described later, is stored in a buffer RAM inside the HDD.
However, conventionally, partially-missed data is not utilized effectively. Namely, even if an ECC error occurs in a reading process and partially-missed data is stored in the buffer RAM, the HDD does not adopt the partially-missed data as dummy data to minimize frame skipping area on the display screen.
For example, a dynamic image file is stored in several hundreds of sectors per frame, depending on the compression type. As a result, when a plurality of optional data is continuously transferred to the host system, the frame skipping area expands on the display screen and it is extremely hard for a viewer to watch the screen.
Accordingly, the present invention is directed to a magnetic recording/reproducing apparatus that substantially obviates one or more of problems due to limitations and disadvantages of the prior art.
In accordance with the purpose of the present invention, as embodied and broadly described, the present invention is directed to a data reproducing unit which reads data from are cording medium according to an inputted designation in a reading process and outputs the data within a predetermined time. The data reading unit comprises means for detecting an error which causes in the reading process, a timer for timing the reading process for the data, means for reading the designated data from the recording medium, a memory for storing the data read from the recording medium even though part of the data may be missing, and means for outputting the data stored in the memory within the predetermined time. The reading means re-executes the reading process when an error is detected by the detecting means and stops the re-execution when the predetermined time elapses. And the outputting means outputs the data, part of which is missing, if it is stored in the memory when the re-execution is stopped.
Also in accordance with the present invention, there is provided a data reproducing unit which reads data from a plurality of sectors in a recording medium in each reading process and outputs the data according to an inputted designation within a predetermined time. The data reading unit comprises means for detecting an error which causes in each reading process, means for determining a permissible time for each reading process based on the predetermined time, a timer for timing each process for reading the data from the sector, means for sequentially reading the plurality of data from the sectors, a memory for storing the plurality of data read from the sectors even though part of each read data maybe missing, and means for sequentially outputting data stored in the memory within the predetermined time. The reading means re-executes each reading process when an error is detected in the reading process by the detecting means and stops the re-execution when the permissible time elapses. And the outputting means outputs the data, part of which is missing, if it is stored in the memory when the re-execution is stopped.
Further in accordance with the present invention, there is provided a magnetic recording/reproducing apparatus which transfers data to a host system according to a designation issued by the host system within a predetermined time. The magnetic recording/reproducing apparatus comprises a magnetic disk unit for storing the data in a plurality of sectors, means for detecting an error which causes in each reading process, means for determining a permissible time for each reading process based on the predetermined time, a timer for timing each process for reading the data from the sector, means for sequentially reading the data from the sectors, a memory for storing the data read from the sectors even though part of the read data may be missing, and means for sequentially transferring the data stored in the memory to the host system within the predetermined time. The reading means re-executes each reading process when an error is detected in the reading process by the detecting means and stops the re-execution when the permissible time elapses. And the transferring means transfers the designated data, part of which is missing, if it is stored in the memory when the re-execution is stopped.
Also in accordance with the present invention, there is provided a method for reproducing data from a plurality of sectors in a recording medium and outputting the data according to an inputted designation within a predetermined time. The method comprises sequentially reading the data from the sectors, storing the data read from the sectors in a memory even though part of the read data may be missing, timing each process for reading the data from the sector, outputting the data stored in the memory within the predetermined time, detecting an error which causes in the reading, determining a permissible time for each reading based on the predetermined time, re-executing each reading when the error is detected in the reading, stopping the re-executing when the permissible time elapses, and outputting the data, part of which is missing, if it is stored in the memory when the re-executing is stopped.